V2EX  ›  英汉词典

Exit Code

释义 Definition

exit code(也叫 exit status)指程序/命令结束时返回给操作系统的状态码,用于表示运行结果是否成功以及失败原因的类型。通常 0 表示成功非 0 表示出错或异常(不同程序的含义可能不同)。

发音 Pronunciation (IPA)

/ˈɛɡzɪt koʊd/(美); /ˈɛɡzɪt kəʊd/(英)

例句 Examples

The script failed with exit code 1.
脚本运行失败,退出码为 1。

If the process returns a nonzero exit code, the deployment pipeline will stop and log the error for investigation.
如果该进程返回非零退出码,部署流水线会停止并记录错误以便排查。

词源 Etymology

exit 来自拉丁语 exire(“出去、离开”),在计算机语境中引申为“程序退出/结束”;code 来自拉丁语 codex(“法典、成文规则”),在现代英语中常指“编码/代码/代号”。合起来 exit code 就是“程序结束时给出的代号/状态码”。

相关词 Related Words

文学与著作 Literary Works

  • The C Programming Language(Kernighan & Ritchie):讨论程序返回值与进程结束状态的经典来源之一
  • Advanced Programming in the UNIX Environment(W. Richard Stevens):系统讲解进程终止与退出状态(exit status/exit code)的权威教材
  • Linux man-pages(如 exit(3), wait(2)):在手册页中大量出现并定义退出状态/退出码的约定与用法
关于   ·   帮助文档   ·   自助推广系统   ·   博客   ·   API   ·   FAQ   ·   Solana   ·   694 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 13ms · UTC 21:31 · PVG 05:31 · LAX 13:31 · JFK 16:31
♥ Do have faith in what you're doing.